import { createRouter, createWebHistory, RouteRecordRaw } from "vue-router";

// 创建一个路由实例
const routes: Array<RouteRecordRaw> = [
	{
		path: "/dialog",
		name: "dialog",
		component: () => import("../page/Dialog.vue"),
	},
	{
		path: "/globalcss",
		name: "GlobalCss",
		component: () => import("../page/GlobalCss.vue"),
	},
	{
		path: "/table",
		name: "Table",
		component: () => import("../page/Table.vue"),
	},
	{
		path: "/form",
		name: "Form",
		component: () => import("../page/Form.vue"),
	},
	{
		path: "/a-form",
		name: "AForm",
		component: () => import("../page/AForm.vue"),
	},
	{
		path: "/a-pagination",
		name: "AForm",
		component: () => import("../page/APagination.vue"),
	},
	{
		path: "/a-message",
		name: "AMessage",
		component: () => import("../page/AMessage.vue"),
	},
	{
		path: "/pinia",
		name: "Pinia",
		component: () => import("../page/Pinia.vue"),
	},
];

const router = createRouter({
	history: createWebHistory(),
	routes,
});

export default router;
